package com.hairline.controller;

import com.hairline.bean.vo.BaseRespVo;
import com.hairline.bean.vo.ListVo;
import com.hairline.service.WxCommentServices;
import com.hairline.service.WxCommentServicesImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

@RestController
@RequestMapping("wx/comment")
public class WxCommentController {
    @Autowired
    private WxCommentServices wxCommentServices;
    @RequestMapping("list")
    public BaseRespVo getCommentList(Integer valueId,
                                     Integer type,
                                     Integer showType,
                                     Integer page,
                                     Integer size){
       Map vo = wxCommentServices.getCommentList(valueId,type,showType,page,size);
        return BaseRespVo.ok(vo);
    }
    @RequestMapping("count")
    public BaseRespVo getCount(Integer valueId,Integer type){
        Map vo=wxCommentServices.getCount( valueId, type);

        return BaseRespVo.ok(vo);
    }
}
